﻿using System;
using System.Collections.Generic;
using System.Linq.Expressions;

namespace NeGroid.ChampionshipManager.Persistance
{
	public interface IRepository<TEntity>
		where TEntity : class 
	{
		IEnumerable<TEntity> Get(
			Expression<Func<TEntity, bool>> filter = null,
			SortOptions sortOptions = null,
			string includeProperties = "");
		void Insert(TEntity entity);
		void Delete(TEntity entity);
		void Update(TEntity entity);

		void SaveChanges();
	}
}
